﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace ajayumi.Test.WebUI.Utils
{
    [Serializable]
    public class TestInfo
    {
        public List<TestInfo> Tests
        {
            get
            {
                List<TestInfo> lst = new List<TestInfo>();
                for (int i = 1; i <= 100; i++)
                {
                    lst.Add(new TestInfo() { Id = i, Code = (10000 + i).ToString(), Name = string.Concat("Test", i) });
                }
                return lst;
            }
        }



        public int Id { get; set; }
        public string Code { get; set; }
        public string Name { get; set; }

        internal List<TestInfo> GetList(int index, int size)
        {
            List<TestInfo> lst = new List<TestInfo>();
            for (int i = 1; i <= size; i++)
            {
                int id = i + (index - 1) * size;
                lst.Add(new TestInfo()
                {
                    Id = id,
                    Code = (10000 + id).ToString(),
                    Name = string.Concat("Test", id)
                });

            }

            return lst;
        }
    }
}